<!--
 * @Author: fanyaqing
 * @Date: 2021-08-05 15:06:12
 * @LastEditTime: 2021-08-05 15:52:51
 * @LastEditors: fanyaqing
 * @Description: 
 * @FilePath: \supermall\src\views\home\childComponents\RecommendView.vue
-->
<template>
  <div class="recommends">
    <div class="recommends-item" v-for="(item, index) in recommends" :key="index">
      <a :href="item.link">
        <img :src="item.image">
        <div>{{item.title}}</div>
      </a>
    </div>
  </div>
  
</template>
<script>
export default {
  props:{
    recommends:{
      type:Array,
      default:()=>{
        return []
      }
    }
  },
  data() {
    return {
      
    }
  },
}
</script>
<style scoped>
  .recommends{
    display:flex;
    padding-bottom: 20px;
    border-bottom: 10px solid #eee;
  }
  .recommends-item{
    flex:1;
    width:80px;
    text-align: center;
  }
  .recommends-item img{
    width:100%;
    padding: 5px;
  }
</style>